<template>
    <div>
        <h2>优惠券核销列表</h2>
        <table class="table table-bordered">
            <tbody>
                <tr>
                    <td>门店id</td>
                    <td>会员id</td>
                    <td>优惠券类型</td>
                    <td>使用时间</td>
                    <td>操作</td>                   
                </tr>

                <tr v-for="item in query.list">
                    <td>{{item.ShopId}}</td>
                    <td>{{item.MemberId}}</td>
                    <td>{{item.DiscoutId}}</td>
                    <td>{{item.UseTime}}</td>
                    <td>操作</td>                   
                </tr>
            </tbody>
        </table>
    </div>
</template>

<script setup lang="ts">
import{ref,reactive,onMounted} from 'vue'
import {useRouter,useRoute} from 'vue-router'
import axios from 'axios';
const router=useRouter();
const route=useRoute();


onMounted(()=>{
    shoulist();
})
const query:any=reactive({
    list:[],
})

const shoulist=()=>{
    axios({
        url:'/api/Discount/GetDiscountCountList',
        method:'get',
    })
    .then(res=>{
        console.log(res);
        query.list=res.data;

    })
    .catch(err=>{
        console.log(err);
    })
}
</script>

<style scoped>

</style>